home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 7 / Amiga Format AFCD07 (Dec 1996, Issue 91).iso / serious / shareware / comms / non-internet / samba / source / local.h < prev    next >
C/C++ Source or Header  |  1996-06-26  |  5KB  |  168 lines

  1. /* local definitions for file server */
  2. #ifndef _LOCAL_H
  3. #define _LOCAL_H
  4.  
  5. /* This defines the section name in the configuration file that will contain */
  6. /* global parameters - that is, parameters relating to the whole server, not */
  7. /* just services. This name is then reserved, and may not be used as a       */
  8. /* a service name. It will default to "global" if not defined here.          */
  9. #define GLOBAL_NAME "global"
  10. #define GLOBAL_NAME2 "globals"
  11.  
  12. /* This defines the section name in the configuration file that will
  13.    refer to the special "homes" service */
  14. #define HOMES_NAME "homes"
  15.  
  16. /* This defines the section name in the configuration file that will
  17.    refer to the special "printers" service */
  18. #define PRINTERS_NAME "printers"
  19.  
  20. /* This defines the name of the printcap file. It is MOST UNLIKELY that
  21.    this will change BUT! Specifying a file with the format of a printcap
  22.    file but containing only a subset of the printers actually in your real 
  23.    printcap file is a quick-n-dirty way to allow dynamic access to a subset
  24.    of available printers.
  25. */
  26. #define PRINTCAP_NAME "/etc/printcap"
  27.  
  28. /* set these to define the limits of the server. NOTE These are on a
  29.    per-client basis. Thus any one machine can't connect to more than
  30.    MAX_CONNECTIONS services, but any number of machines may connect at
  31.    one time. */
  32. #define MAX_CONNECTIONS 127
  33. #define MAX_OPEN_FILES 100
  34.  
  35. /* the max number of connections that the smbstatus program will show */
  36. #define MAXSTATUS 1000
  37.  
  38. /* max number of directories open at once */
  39. /* note that with the new directory code this no longer requires a
  40.    file handle per directory, but large numbers do use more memory */
  41. #define MAXDIR 64
  42.  
  43. #define WORDMAX 0xFFFF
  44.  
  45.  
  46. /* separators for lists */
  47. #define LIST_SEP " \t,;:\n\r"
  48.  
  49. #ifndef LOCKDIR
  50. #define LOCKDIR "/tmp/samba"
  51. #endif
  52.  
  53. /* this is where browse lists are kept in the lock dir */
  54. #define SERVER_LIST "browse.dat"
  55.  
  56. /* the print command on the server, %s is replaced with the filename  */
  57. /* note that the -r removes the file after printing - you'll run out  */
  58. /* of disk pretty quickly if you don't. This command is only used as  */
  59. /* the default - it can be overridden in the configuration file.      */
  60. #define PRINT_COMMAND "lpr -r %s"
  61.  
  62. /* the lpq command on the server. the printername is passed as an argument */
  63. #ifndef LPQ_COMMAND
  64. #define LPQ_COMMAND "lpq -P"
  65. #endif
  66.  
  67. /* shall guest entries in printer queues get changed to user entries,
  68.    so they can be deleted using the windows print manager? */
  69. #define LPQ_GUEST_TO_USER
  70.  
  71. /* shall filenames with illegal chars in them get mangled in long
  72.    filename listings? */
  73. #define MANGLE_LONG_FILENAMES 
  74.  
  75. /* define this if you want to stop spoofing with .. and soft links
  76.    NOTE: This also slows down the server considerably */
  77. #define REDUCE_PATHS
  78.  
  79. /* the size of the directory cache */
  80. #define DIRCACHESIZE 20
  81.  
  82. /* what type of filesystem do we want this to show up as in a NT file
  83.    manager window? */
  84. #define FSTYPE_STRING "Samba"
  85.  
  86. /* we have two time standards - local and GMT. This will try to sort them out.
  87.  */
  88.  
  89. #define LOCAL_TO_GMT 1
  90. #define GMT_TO_LOCAL (-1)
  91.  
  92. /* do you want smbd to send a 1 byte packet to nmbd to trigger it to start 
  93.    when smbd starts? */
  94. #ifndef PRIME_NMBD
  95. #define PRIME_NMBD 1
  96. #endif
  97.  
  98. /* do you want session setups at user level security with a invalid
  99.    password to be rejected or allowed in as guest? WinNT rejects them
  100.    but it can be a pain as it means "net view" needs to use a password 
  101.  
  102.    You have 3 choices:
  103.  
  104.    GUEST_SESSSETUP = 0 means session setups with an invalid password
  105.    are rejected.
  106.  
  107.    GUEST_SESSSETUP = 1 means session setups with an invalid password
  108.    are rejected, unless the username does not exist, in which case it
  109.    is treated as a guest login
  110.  
  111.    GUEST_SESSSETUP = 2 means session setups with an invalid password
  112.    are treated as a guest login
  113.  
  114.    Note that GUEST_SESSSETUP only has an effect in user or server
  115.    level security.
  116.    */
  117. #ifndef GUEST_SESSSETUP
  118. #define GUEST_SESSSETUP 0
  119. #endif
  120.  
  121. /* the default pager to use for the client "more" command. Users can
  122.    override this with the PAGER environment variable */
  123. #ifndef PAGER
  124. #define PAGER "more"
  125. #endif
  126.  
  127. /* the size of the uid cache used to reduce valid user checks */
  128. #define UID_CACHE_SIZE 4
  129.  
  130. /* the following control timings of various actions. Don't change 
  131.    them unless you know what you are doing. These are all in seconds */
  132. #define DEFAULT_SMBD_TIMEOUT (60*60*24*7)
  133. #define SMBD_RELOAD_CHECK (10)
  134. #define SHARE_MODES_CHECK (10)
  135. #define SHARE_MODES_CLEAN (300)
  136. #define IDLE_CLOSED_TIMEOUT (30)
  137. #define DPTR_IDLE_TIMEOUT (120)
  138. #define SMBD_SELECT_LOOP (10)
  139. #define NMBD_SELECT_LOOP (10)
  140. #define BROWSE_INTERVAL (60)
  141. #define REGISTRATION_INTERVAL (10*60)
  142. #define NMBD_INETD_TIMEOUT (120)
  143. #define NMBD_MAX_TTL (24*60*60)
  144. #define LPQ_LOCK_TIMEOUT (5)
  145.  
  146. /* the following are in milliseconds */
  147. #define LOCK_RETRY_TIMEOUT (100)
  148.  
  149. /* do you want to dump core (carefully!) when an internal error is
  150.    encountered? Samba will be careful to make the core file only
  151.    accessible to root */
  152. #define DUMP_CORE 1
  153.  
  154. /* what is the longest significant password available on your system? 
  155.  Knowing this speeds up password searches a lot */
  156. #ifndef PASSWORD_LENGTH
  157. #define PASSWORD_LENGTH 8
  158. #endif
  159.  
  160. #define SMB_ALIGNMENT 1
  161.  
  162.  
  163. /* shall we support browse requests via a FIFO to nmbd? */
  164. #define ENABLE_FIFO 1
  165.  
  166.  
  167. #endif
  168.